The present disclosure relates to access control of computer-readable content and, more specifically, to preview serving of computer-readable content from an external preview service.
In a complex collaborative or social software offering, files may be stored in a number of places. For instance, in IBM Connections and SmartCloud, files may exist in Connections files, Connections Content Manager, as attachments to a number of services including wilds, forums, blogs, in mail messages, in chat file transfers, in virtual meeting rooms, and other places. In all these cases, it is often desirable to give the end user a preview of the file, be it a document, large image, video or other file. Often previews are displayed in large sets, from just a few to sometimes displaying hundreds of small thumbnail previews on a single page view.
Each preview request may result in a call to the application controlling access. If all services are distributed among a number of servers, either the thumbnail service is not centralized, or at least some of the services will incur remote method invocations to the component which controls the content access. This is highly inefficient as, for example, fifty thumbnails on a page would result in fifty such remote calls and could result in fifty database queries to check access.
Some efficiency may be found in batching preview requests so all the required thumbnails are returned in a single response. These responses may be part of a single response for all thumbnails, may be with hypertext markup language (HTML) of the page, or may be additional parts added to a feed of some kind. Batching typically improves performance but with significant added complexity to the client application. For instance, normal image tags and uniform resource locators (URLs) for single images may no longer be used, and a scripting language may be necessary to parse responses and lay out images in most cases. MIME HTML (MHTML) could potentially do this transparently, but MHTML is supported for archival, not service of, web pages. Use of these approaches also implies a very tight binding between the preview or thumbnail service and the application or component controlling access. The thumbnail or preview service becomes a feature of the component or application, which makes it difficult to apply across a number of independent services.